<template>
    <h1>(用户)借款项目列表</h1>

    <table>
        <thead>
            <tr>
                <th>借款款项ID</th>
                <th>借款款项名称</th>
                <th>借款最高金额</th>
                <th>借款最高年限</th>
                <th>预计月还款金额</th>
                <th>利息值</th>
                <th>操作</th>
            </tr>
        </thead>

        <tbody>
            <tr v-for=" item in ShowBorrow">
                <td>{{ item.BM_Id }}</td>
                <td>{{ item.BM_Name }}</td>
                <td>{{ item.BM_Money }}</td>
                <td>{{ item.BM_Year }}</td>
                <td></td>
                <td>{{ item.BI_Interest }}</td>
                <td>
                    <input type="button" value="借款" @click="" />
                </td>
            </tr>
        </tbody>

    </table>

</template>

<script setup lang="ts">
import { ref,onMounted } from 'vue';
import axios from 'axios';
//import { useRouter } from 'vue-router';

//const router = useRouter();

const ShowBorrow = ref([{
    BM_Id:'',
    BM_Name:'',
    BM_Money:'',
    BM_Year:'',
    BI_Interest:'',
}])

onMounted(()=>{
axios({
    method:'get',
    url:'',

    })
    .then(function(res){
        ShowBorrow.value = res.data[0];       
    })
    .catch(function(err){
        console.log(err);
    })
})



</script>